/**
 * Copyright 2013 Snehasish Roy
 */
/**
 * This file is part of CodeIt! ©.
 *
 * CodeIt! © is free software: you can redistribute it and/or modify it under
 * the terms of the GNU General Public License as published by the Free Software
 * Foundation, either version 3 of the License, or (at your option) any later
 * version.
 *
 * CodeIt! © is distributed in the hope that it will be useful, but WITHOUT ANY
 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
 * A PARTICULAR PURPOSE. See the GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License along with
 * CodeIt! ©. If not, see <http://www.gnu.org/licenses/>.
 */
package workingwithideone;

import java.awt.KeyboardFocusManager;
import java.awt.Toolkit;
import java.awt.datatransfer.Clipboard;
import java.awt.datatransfer.StringSelection;
import java.beans.PropertyChangeEvent;
import java.beans.PropertyChangeListener;
import java.io.BufferedReader;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
import java.io.PrintWriter;
import java.util.Hashtable;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.swing.JComponent;
import javax.swing.JFileChooser;
import javax.swing.JOptionPane;
import javax.swing.SwingUtilities;
import org.ksoap.SoapPrimitive;

/**
 * OutputPanel.java Purpose: Controls everything related to output panel
 *
 * @author Snehasish Roy
 * @version 1.0 17/06/13
 */
public class OutputPanel extends javax.swing.JPanel {

    private static final long serialVersionUID = 1L;
    CodeIt ref;
    String srcCode;
    boolean privateEnabled, runnable;
    Integer language;

    public OutputPanel() {
    }

    /**
     * Initialization of data members
     *
     * @param ref CodeIt reference
     * @param language Integer language code
     * @param runnable set to true to execute the program
     * @param privateEnabled set to true to make the submission private
     */
    public OutputPanel(CodeIt ref, Integer language, boolean runnable, boolean privateEnabled) {
        initComponents();
        this.ref = ref;
        this.language = language;
        this.privateEnabled = privateEnabled;
        this.runnable = runnable;
        disableProgress();
        enableResubmit(false);
        jEditorPane3.setEditable(false);
        jEditorPane4.setEditable(false);
        jEditorPane5.setEditable(false);
        //handleFocus();
    }

    /**
     * Enables auto scrolling between components when user presses TAB or
     * ALT+TAB
     */
    public void handleFocus() {
        KeyboardFocusManager.getCurrentKeyboardFocusManager()
                .addPropertyChangeListener("focusOwner",
                new PropertyChangeListener() {
                    @Override
                    public void propertyChange(PropertyChangeEvent evt) {
                        if (!(evt.getNewValue() instanceof JComponent)) {
                            return;
                        }
                        JComponent focused = (JComponent) evt.getNewValue();

                        if (OutputPanel.this.isAncestorOf(focused)) {
                            //System.out.println("Scrolling to " + focused.getName());
                            OutputPanel.this.scrollRectToVisible(focused.getBounds());
                        }
                    }
                });
    }

    /**
     * Controls the resubmission of a code
     *
     * @param val set to true if resubmission should be allowed
     */
    public void enableResubmit(boolean val) {
        jLabel31.setEnabled(val);
        jButton1.setVisible(val);
    }

    /**
     * Shows submission status
     *
     * @param str String to be set as status
     */
    public void setStatus(String str) {
        jLabel30.setText(str);
    }

    /**
     * Shows Submission progress by showing a progress bar and submission status
     */
    public void enableProgress() {
        jProgressBar1.setVisible(true);
        jLabel30.setVisible(true);
    }

    /**
     * Hides Submission progress after successful submission
     */
    public void disableProgress() {
        jProgressBar1.setVisible(false);
        jLabel30.setVisible(false);
    }

    /**
     * Disables the Edit and Provide with new Input label to avoid multiple
     * panels being added
     */
    public void disableFurtherInput() {
        jLabel4.setEnabled(false);
        jLabel12.setEnabled(false);
    }

    /**
     * Enables the Edit and Provide with new Input to allow resubmission
     */
    public void enableFurtherInput() {
        jLabel4.setEnabled(true);
        jLabel12.setEnabled(true);
    }

    //Auto Generated by NetBeans IDE 
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jLabel1 = new javax.swing.JLabel();
        jLabel2 = new javax.swing.JLabel();
        jTextField1 = new javax.swing.JTextField();
        jLabel3 = new javax.swing.JLabel();
        jLabel4 = new javax.swing.JLabel();
        jLabel5 = new javax.swing.JLabel();
        jLabel6 = new javax.swing.JLabel();
        jScrollPane1 = new javax.swing.JScrollPane();
        jEditorPane1 = new javax.swing.JEditorPane();
        jLabel7 = new javax.swing.JLabel();
        jScrollPane2 = new javax.swing.JScrollPane();
        jEditorPane2 = new javax.swing.JEditorPane();
        jLabel8 = new javax.swing.JLabel();
        jScrollPane3 = new javax.swing.JScrollPane();
        jEditorPane3 = new javax.swing.JEditorPane();
        jLabel9 = new javax.swing.JLabel();
        jScrollPane4 = new javax.swing.JScrollPane();
        jEditorPane4 = new javax.swing.JEditorPane();
        jLabel11 = new javax.swing.JLabel();
        jLabel12 = new javax.swing.JLabel();
        jLabel13 = new javax.swing.JLabel();
        jLabel14 = new javax.swing.JLabel();
        jLabel15 = new javax.swing.JLabel();
        jLabel16 = new javax.swing.JLabel();
        jLabel17 = new javax.swing.JLabel();
        jLabel18 = new javax.swing.JLabel();
        jButton1 = new javax.swing.JButton();
        jLabel19 = new javax.swing.JLabel();
        jLabel20 = new javax.swing.JLabel();
        jLabel21 = new javax.swing.JLabel();
        jLabel22 = new javax.swing.JLabel();
        jButton2 = new javax.swing.JButton();
        jLabel10 = new javax.swing.JLabel();
        jLabel23 = new javax.swing.JLabel();
        jLabel24 = new javax.swing.JLabel();
        jPanel1 = new javax.swing.JPanel();
        jScrollPane5 = new javax.swing.JScrollPane();
        jEditorPane5 = new javax.swing.JEditorPane();
        jLabel25 = new javax.swing.JLabel();
        jLabel26 = new javax.swing.JLabel();
        jLabel27 = new javax.swing.JLabel();
        jLabel28 = new javax.swing.JLabel();
        jLabel29 = new javax.swing.JLabel();
        jProgressBar1 = new javax.swing.JProgressBar();
        jLabel30 = new javax.swing.JLabel();
        jLabel31 = new javax.swing.JLabel();

        setPreferredSize(new java.awt.Dimension(1200, 1200));

        jLabel1.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel1.setText("Output Window");

        jLabel2.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel2.setText("permaLink of your Source Code:");

        jTextField1.setFont(new java.awt.Font("SansSerif", 2, 14)); // NOI18N
        jTextField1.setText("http://ideone.com/----------");

        jLabel3.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel3.setText("Source Code");

        jLabel4.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel4.setText("Edit");
        jLabel4.setToolTipText("Allows you to edit your source code and resubmit it");
        jLabel4.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel4.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel4MouseClicked(evt);
            }
        });

        jLabel5.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel5.setText("Copy to Clipboard");
        jLabel5.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel5.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel5MouseClicked(evt);
            }
        });

        jLabel6.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel6.setText("Save Source Code");
        jLabel6.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel6.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel6MouseClicked(evt);
            }
        });

        jEditorPane1.setFont(new java.awt.Font("SansSerif", 0, 14)); // NOI18N
        jEditorPane1.setPreferredSize(new java.awt.Dimension(1024, 30));
        jScrollPane1.setViewportView(jEditorPane1);

        jLabel7.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel7.setText("Input");

        jEditorPane2.setFont(new java.awt.Font("SansSerif", 0, 14)); // NOI18N
        jScrollPane2.setViewportView(jEditorPane2);

        jLabel8.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel8.setText("Output");

        jEditorPane3.setFont(new java.awt.Font("SansSerif", 0, 14)); // NOI18N
        jScrollPane3.setViewportView(jEditorPane3);

        jLabel9.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel9.setText("stderr (Standard Error)");

        jEditorPane4.setFont(new java.awt.Font("SansSerif", 0, 14)); // NOI18N
        jScrollPane4.setViewportView(jEditorPane4);

        jLabel11.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel11.setText("Clone It !");
        jLabel11.setToolTipText("Make a clone of your submission");
        jLabel11.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel11.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel11MouseClicked(evt);
            }
        });

        jLabel12.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel12.setText("Provide new Input");
        jLabel12.setToolTipText("Allows you to provide a new input for the submission");
        jLabel12.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel12.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel12MouseClicked(evt);
            }
        });

        jLabel13.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel13.setText("Copy to Clipboard");
        jLabel13.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel13.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel13MouseClicked(evt);
            }
        });

        jLabel14.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel14.setText("Save Input File");
        jLabel14.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel14.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel14MouseClicked(evt);
            }
        });

        jLabel15.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel15.setText("Copy to Clipboard");
        jLabel15.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel15.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel15MouseClicked(evt);
            }
        });

        jLabel16.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel16.setText("Save Output to file");
        jLabel16.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel16.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel16MouseClicked(evt);
            }
        });

        jLabel17.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel17.setText("Copy to Clipboard");
        jLabel17.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel17.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel17MouseClicked(evt);
            }
        });

        jLabel18.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel18.setText("Save stderr to file");
        jLabel18.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel18.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel18MouseClicked(evt);
            }
        });

        jButton1.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jButton1.setText("Submit");
        jButton1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton1ActionPerformed(evt);
            }
        });

        jLabel19.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel19.setText("Time Consumed:");

        jLabel20.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel20.setText("- s");

        jLabel21.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel21.setText("Memory Utilized:");

        jLabel22.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel22.setText("----  MB");

        jButton2.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jButton2.setText("New Code");
        jButton2.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton2ActionPerformed(evt);
            }
        });

        jLabel10.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel10.setText("Private");

        jLabel23.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel23.setText("Language:");

        jLabel24.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel24.setText("Default");

        jPanel1.setBackground(new java.awt.Color(0, 0, 0));

        javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
        jPanel1.setLayout(jPanel1Layout);
        jPanel1Layout.setHorizontalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 0, Short.MAX_VALUE)
        );
        jPanel1Layout.setVerticalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 9, Short.MAX_VALUE)
        );

        jEditorPane5.setFont(new java.awt.Font("SansSerif", 0, 14)); // NOI18N
        jScrollPane5.setViewportView(jEditorPane5);

        jLabel25.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel25.setText("Compilation Info");

        jLabel26.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel26.setText("Copy to Clipboard");
        jLabel26.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel26.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel26MouseClicked(evt);
            }
        });

        jLabel27.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel27.setText("Save Compilation Info");
        jLabel27.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel27.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel27MouseClicked(evt);
            }
        });

        jLabel28.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel28.setText("Signal Raised:");

        jLabel29.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel29.setText("----------");
        jLabel29.setToolTipText("Signal raised by the submission");

        jProgressBar1.setCursor(new java.awt.Cursor(java.awt.Cursor.WAIT_CURSOR));
        jProgressBar1.setIndeterminate(true);

        jLabel30.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel30.setText("Connecting...........");

        jLabel31.setFont(new java.awt.Font("SansSerif", 1, 14)); // NOI18N
        jLabel31.setText("Upload Input file");
        jLabel31.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        jLabel31.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jLabel31MouseClicked(evt);
            }
        });

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
        this.setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addGap(0, 0, 0)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addGroup(layout.createSequentialGroup()
                        .addComponent(jLabel25)
                        .addGap(117, 117, 117)
                        .addComponent(jLabel28)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel29, javax.swing.GroupLayout.PREFERRED_SIZE, 52, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(102, 102, 102)
                        .addComponent(jLabel26)
                        .addGap(119, 119, 119)
                        .addComponent(jLabel27))
                    .addGroup(layout.createSequentialGroup()
                        .addComponent(jLabel8)
                        .addGap(77, 77, 77)
                        .addComponent(jLabel19)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel20)
                        .addGap(62, 62, 62)
                        .addComponent(jLabel21)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel22)
                        .addGap(71, 71, 71)
                        .addComponent(jLabel15)
                        .addGap(60, 60, 60)
                        .addComponent(jLabel16))
                    .addComponent(jScrollPane3)
                    .addGroup(layout.createSequentialGroup()
                        .addComponent(jLabel9)
                        .addGap(230, 230, 230)
                        .addComponent(jLabel17)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addComponent(jLabel18))
                    .addComponent(jScrollPane4)
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                        .addComponent(jLabel7)
                        .addGap(112, 112, 112)
                        .addComponent(jLabel12)
                        .addGap(103, 103, 103)
                        .addComponent(jLabel13)
                        .addGap(86, 86, 86)
                        .addComponent(jLabel31)
                        .addGap(77, 77, 77)
                        .addComponent(jLabel14))
                    .addGroup(layout.createSequentialGroup()
                        .addComponent(jLabel3)
                        .addGap(99, 99, 99)
                        .addComponent(jLabel11)
                        .addGap(121, 121, 121)
                        .addComponent(jLabel4)
                        .addGap(122, 122, 122)
                        .addComponent(jLabel5)
                        .addGap(110, 110, 110)
                        .addComponent(jLabel6))
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)
                    .addComponent(jScrollPane2)
                    .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addGroup(layout.createSequentialGroup()
                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addGroup(layout.createSequentialGroup()
                                .addComponent(jLabel10)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jLabel2)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, 203, javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addGroup(layout.createSequentialGroup()
                                .addComponent(jButton2)
                                .addGap(278, 278, 278)
                                .addComponent(jLabel1)))
                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(layout.createSequentialGroup()
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addComponent(jProgressBar1, javax.swing.GroupLayout.PREFERRED_SIZE, 195, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addComponent(jLabel30))
                            .addGroup(layout.createSequentialGroup()
                                .addGap(26, 26, 26)
                                .addComponent(jLabel23)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jLabel24, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jButton1))))
                    .addComponent(jScrollPane5))
                .addGap(0, 0, 0))
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addGap(19, 19, 19)
                .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel1)
                            .addComponent(jButton2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                        .addComponent(jProgressBar1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .addComponent(jLabel30))
                .addGap(20, 20, 20)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel2)
                    .addComponent(jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jButton1)
                    .addComponent(jLabel10)
                    .addComponent(jLabel23)
                    .addComponent(jLabel24))
                .addGap(18, 18, 18)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel5)
                    .addComponent(jLabel4)
                    .addComponent(jLabel6)
                    .addComponent(jLabel11)
                    .addComponent(jLabel3))
                .addGap(6, 6, 6)
                .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 208, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                        .addComponent(jLabel12, javax.swing.GroupLayout.PREFERRED_SIZE, 19, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(jLabel7))
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                        .addComponent(jLabel14)
                        .addComponent(jLabel31, javax.swing.GroupLayout.PREFERRED_SIZE, 19, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(jLabel13)))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 164, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel26)
                    .addComponent(jLabel27)
                    .addComponent(jLabel25)
                    .addComponent(jLabel28)
                    .addComponent(jLabel29))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane3, javax.swing.GroupLayout.PREFERRED_SIZE, 202, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel16, javax.swing.GroupLayout.PREFERRED_SIZE, 19, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                        .addComponent(jLabel8)
                        .addComponent(jLabel19)
                        .addComponent(jLabel20)
                        .addComponent(jLabel21)
                        .addComponent(jLabel22)
                        .addComponent(jLabel15)))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane5, javax.swing.GroupLayout.PREFERRED_SIZE, 202, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel9)
                    .addComponent(jLabel17)
                    .addComponent(jLabel18))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane4, javax.swing.GroupLayout.PREFERRED_SIZE, 97, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(0, 0, 0))
        );
    }// </editor-fold>//GEN-END:initComponents

    /**
     * Shows the visibility of the submission
     *
     * @param val Set to true if it is a private submission
     */
    public void setPrivateStatus(boolean val) {
        if (!val) {
            jLabel10.setText("Public");
        } else {
            jLabel10.setText("Private");
        }
    }

    /**
     * Handles setting up a new Edit Menu
     *
     * @param evt Not used
     */
    private void jLabel4MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel4MouseClicked
        //System.out.println("U clicked edit me ");

        /*
         * pass source code, language, privateEnabled, runnable,language identifier, 
         * paste link to the new panel
         * if resubmit button is visible prevent multiple click else set a new Input Menu
         */
        if (jLabel4.isEnabled()) {
            ref.setNewInput(jEditorPane1.getText(), language, runnable, privateEnabled, jLabel24.getText(), "http://ideone.com/----------", false);
            jLabel4.setEnabled(false); // To prevent further clicks
        }
    }//GEN-LAST:event_jLabel4MouseClicked

    /**
     * Handles setting up a new Input
     *
     * @param evt Not used
     */
    private void jLabel12MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel12MouseClicked

        /*
         * pass source code, language, privateEnabled, runnable,language identifier, 
         * paste link to the new panel
         * if resubmit button is visible prevent multiple click
         * else set a new Input Menu
         */

        //System.out.println("U clicked provide new input");
        if (jLabel12.isEnabled()) {
            ref.setNewInput(jEditorPane1.getText(), language, runnable, privateEnabled, jLabel24.getText(), "http://ideone.com/----------", true);
            jLabel12.setEnabled(false);
        }
    }//GEN-LAST:event_jLabel12MouseClicked

    /**
     * Handles Re-submission of a code
     *
     * @param evt Not used
     */
    private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton1ActionPerformed

        //Disable further editing of source code and input
        //Show the progress of submission
        //and start a background thread
        disableSrcCodeAndInput();
        enableProgress();
        Thread thread = new Thread(new CreateSubmission(true, Authentication.userName, Authentication.password, jEditorPane1.getText(), language, jEditorPane2.getText(), runnable, privateEnabled, ref, this));
        thread.start();
    }//GEN-LAST:event_jButton1ActionPerformed

    /**
     * Uploads input file
     *
     * @param evt Not used
     */
    private void jLabel31MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel31MouseClicked

        if (jLabel31.isEnabled()) {
            String input = "";
            JFileChooser ref1 = new JFileChooser();
            int showOpenDialog = ref1.showOpenDialog(null);
            if (showOpenDialog == JFileChooser.APPROVE_OPTION) {
                File inputFile = ref1.getSelectedFile();

                //Extract the content of the file 
                BufferedReader in = null;
                try {
                    in = new BufferedReader(new FileReader(inputFile));
                } catch (FileNotFoundException ex) {
                    Logger.getLogger(OutputPanel.class.getName()).log(Level.SEVERE, null, ex);
                }

                String line;
                try {
                    while ((line = in.readLine()) != null) {
                        //System.out.println(line);
                        input += line;
                        input += "\n";
                    }
                    //show the input file
                    jEditorPane2.setText(input);
                } catch (IOException ex) {
                    Logger.getLogger(OutputPanel.class.getName()).log(Level.SEVERE, null, ex);
                    JOptionPane.showMessageDialog(null, "File can't be opened "
                            + "or it's contents can't be extracted", "Invalid file", JOptionPane.ERROR_MESSAGE);
                }
            }
        }
    }//GEN-LAST:event_jLabel31MouseClicked

    /**
     * Makes the Source Code and Input Editor Pane non editable
     */
    public void disableSrcCodeAndInput() {
        jEditorPane1.setEditable(false);
        jEditorPane2.setEditable(false);
    }

    /**
     * Enables editing of Input Editor Pane
     */
    public void enableInputEditor() {
        jEditorPane2.setEditable(true);
    }

    /**
     * Enables editing of Source Code Editor Pane
     */
    public void enableSrcCode() {
        jEditorPane1.setEditable(true);
    }

    /**
     * Handles setting up a cloned menu
     *
     * @param evt Not used
     */
    private void jLabel11MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel11MouseClicked

        //passes the current source code and input text to be set in MainPanel
        SwingUtilities.invokeLater(new Runnable() {
            @Override
            public void run() {
                ref.displayClonedMainPanel(jEditorPane1.getText(), jEditorPane2.getText());
            }
        });
    }//GEN-LAST:event_jLabel11MouseClicked

    /**
     * Handles setting up a new Code Menu
     *
     * @param evt Not used
     */
    private void jButton2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton2ActionPerformed
        ref.displayNewCodeMenu();
    }//GEN-LAST:event_jButton2ActionPerformed

    /**
     * Copies a string to system clipboard
     *
     * @param str String to be copied to system clipboard
     */
    public void copyToClipBoard(String str) {
        StringSelection copiedString = new StringSelection(str);
        Clipboard clipboard = Toolkit.getDefaultToolkit().getSystemClipboard();
        clipboard.setContents(copiedString, copiedString);
    }

    /**
     * Copies source code to ClipBoard
     *
     * @param evt Not used
     */
    private void jLabel5MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel5MouseClicked
        copyToClipBoard(jEditorPane1.getText());
        JOptionPane.showMessageDialog(null, "Source Code copied to clipboard", "Success", JOptionPane.INFORMATION_MESSAGE);
    }//GEN-LAST:event_jLabel5MouseClicked

    /**
     * Copies input to ClipBoard
     *
     * @param evt Not Used
     */
    private void jLabel13MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel13MouseClicked
        copyToClipBoard(jEditorPane2.getText());
        JOptionPane.showMessageDialog(null, "Input file copied to clipboard", "Success", JOptionPane.INFORMATION_MESSAGE);
    }//GEN-LAST:event_jLabel13MouseClicked

    /**
     * Copies Compilation info to clipboard
     *
     * @param evt
     */
    private void jLabel26MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel26MouseClicked
        copyToClipBoard(jEditorPane3.getText());
        JOptionPane.showMessageDialog(null, "Compilation info copied to clipboard", "Success", JOptionPane.INFORMATION_MESSAGE);
    }//GEN-LAST:event_jLabel26MouseClicked

    /**
     * Copies Output file to clipboard
     *
     * @param evt Not used
     */
    private void jLabel15MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel15MouseClicked
        copyToClipBoard(jEditorPane5.getText());
        JOptionPane.showMessageDialog(null, "Output file copied to clipboard", "Success", JOptionPane.INFORMATION_MESSAGE);
    }//GEN-LAST:event_jLabel15MouseClicked

    /**
     * Copies Stderr to clipboard
     *
     * @param evt
     */
    private void jLabel17MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel17MouseClicked
        copyToClipBoard(jEditorPane4.getText());
        JOptionPane.showMessageDialog(null, "Stderr copied to clipboard", "Success", JOptionPane.INFORMATION_MESSAGE);
    }//GEN-LAST:event_jLabel17MouseClicked

    /**
     * Write to a file the provided string
     *
     * @param str String to be written to file
     */
    private void writeToFile(String str) {
        final JFileChooser fc = new JFileChooser();
        int returnVal = fc.showSaveDialog(this);
        if (returnVal == JFileChooser.APPROVE_OPTION) {
            File file = fc.getSelectedFile();
            try {
                PrintWriter pw = new PrintWriter(file);
                pw.print(str);
                pw.close();
                JOptionPane.showMessageDialog(null, file + " saved successfully", "Success", JOptionPane.INFORMATION_MESSAGE);
            } catch (FileNotFoundException ex) {
                JOptionPane.showMessageDialog(null, "Unable to write to specified fle", "Error", JOptionPane.ERROR_MESSAGE);
            }
        }
    }

    /**
     * Save source code to user defined file
     *
     * @param evt Not used
     */
    private void jLabel6MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel6MouseClicked
        writeToFile(jEditorPane1.getText());
    }//GEN-LAST:event_jLabel6MouseClicked

    /**
     * Save input to user defined file
     *
     * @param evt Not used
     */
    private void jLabel14MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel14MouseClicked
        writeToFile(jEditorPane2.getText());
    }//GEN-LAST:event_jLabel14MouseClicked

    /**
     * Save Compilation Info to user defined file
     *
     * @param evt Not used
     */
    private void jLabel27MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel27MouseClicked
        writeToFile(jEditorPane3.getText());
    }//GEN-LAST:event_jLabel27MouseClicked

    /**
     * Save Output to user defined file
     *
     * @param evt Not used
     */
    private void jLabel16MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel16MouseClicked
        writeToFile(jEditorPane5.getText());
    }//GEN-LAST:event_jLabel16MouseClicked

    /**
     * Save Stderr to user defined file
     *
     * @param evt Not used
     */
    private void jLabel18MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jLabel18MouseClicked
        writeToFile(jEditorPane4.getText());
    }//GEN-LAST:event_jLabel18MouseClicked

    /**
     * Interprets the status returned by getSubmissionDetails method of Ideone
     * API
     *
     * @param status Integer status code
     */
    public void interpretStatus(Integer status) {
        switch (status) {
            case 0:
                JOptionPane.showMessageDialog(null, "Not Running: Link has been created with run parameter set to false", "Submission Status", JOptionPane.INFORMATION_MESSAGE);
                break;
            case 11:
                JOptionPane.showMessageDialog(null, "Compilation Error", "Submission Status", JOptionPane.ERROR_MESSAGE);
                break;
            case 12:
                JOptionPane.showMessageDialog(null, "Runtime Error", "Submission Status", JOptionPane.ERROR_MESSAGE);
                break;
            case 13:
                JOptionPane.showMessageDialog(null, "Time Limit Exceeded (Your submission took more than 5 sec to execute)", "Submission Status", JOptionPane.ERROR_MESSAGE);
                break;
            case 15:
                JOptionPane.showMessageDialog(null, "Success", "Submission Status", JOptionPane.INFORMATION_MESSAGE);
                break;
            case 17:
                JOptionPane.showMessageDialog(null, "Memory Limit Exceeded", "Submission Status", JOptionPane.ERROR_MESSAGE);
                break;
            case 19:
                JOptionPane.showMessageDialog(null, "Illegal System Call", "Submission Status", JOptionPane.ERROR_MESSAGE);
                break;
            case 20:
                JOptionPane.showMessageDialog(null, "Internal Error: Try to submit again", "Submission Status", JOptionPane.ERROR_MESSAGE);
                break;
        }
    }

    /**
     * Interprets signal to User Readable String
     *
     * @param signal Integer Signal Code
     */
    public void interpretSignal(Integer signal) {
        boolean flag = false;
        switch (signal) {
            case 11:
                setSignal("SIGSEGV");
                flag = true;
                break;
            case 25:
                setSignal("SIGXFSZ");
                flag = true;
                break;
            case 8:
                setSignal("SIGFPE");
                flag = true;
                break;
            case 6:
                setSignal("SIGABRT");
                flag = true;
                break;
            case -1:
                setSignal("NZEC");
                flag = true;
                break;
            case 9:
                setSignal("SIGKILL");
                flag = true;
                break;

            case 0:
                setSignal("NONE");
                flag = true;
                break;
        }
        if (!flag) {
            setSignal("OTHER");
        }
    }

    /**
     * Sets various labels of panel like memory consumed, time required etc.
     *
     * @param status Integer status returned by getSubmissionDetails
     * @param data HashTable containing all the info
     * @param paste Unique link of the submission
     */
    public void setInfo(Integer status, Hashtable data, String paste) {
        disableProgress();
        enableResubmit(false);
        interpretStatus(status);

        Integer memory = (Integer) data.get("memory");
        Double mem = memory / 1024.0;
        setMemory(Double.toString(mem) + " MB");

        String langName = (String) data.get("langName");
        String langVersion = (String) data.get("langVersion");
        setLanguage(langName + " " + langVersion);

        setPaste("http://ideone.com/" + paste);

        Double time = Double.valueOf(((SoapPrimitive) data.get("time")).toString());
        setTime(time);

        if (data.get("output").equals("")) {
            showOutput(false);
        } else {
            String output = (String) data.get("output");
            showOutput(true);
            setOutput(output);
        }

        if (data.get("cmpinfo").equals("")) {
            showCmpInfo(false);
        } else {
            String cmpInfo = (String) data.get("cmpinfo");
            showCmpInfo(true);
            setCmpInfo(cmpInfo);
        }

        if (data.get("stderr").equals("")) {
            showStdErr(false);
        } else {
            String stderr = (String) data.get("stderr");
            showStdErr(true);
            setStderr(stderr);
        }

        Integer signal = (Integer) data.get("signal");
        //System.out.println(signal);
        interpretSignal(signal);
        enableFurtherInput();
    }

    /**
     * Sets the signal label
     *
     * @param signal Signal to be set
     */
    public void setSignal(String signal) {
        jLabel29.setText(signal);
    }

    /**
     * Sets the memory consumed label
     *
     * @param memory Memory to be set
     */
    public void setMemory(String memory) {
        jLabel22.setText(memory);
    }

    /**
     * Sets the time consumed label
     *
     * @param time Time to be set
     */
    public void setTime(Double time) {
        jLabel20.setText(time.toString() + " s");
    }

    /**
     * Sets the paste of the submission
     *
     * @param paste Paste to be set
     */
    public void setPaste(String paste) {
        jTextField1.setText(paste);
    }

    /**
     * Sets the Source Code of the submission
     *
     * @param source Source code to be set
     */
    public void setSrcCode(String source) {
        //srcCode = source;
        jEditorPane1.setText(source);
    }

    /**
     * Sets the Compilation info of the submission
     *
     * @param cmpinfo Compilation info to be set
     */
    public void setCmpInfo(String cmpinfo) {
        jEditorPane3.setText(cmpinfo);
    }

    /**
     * Sets the output of the submission
     *
     * @param output Output to be set
     */
    public void setOutput(String output) {
        jEditorPane5.setText(output);
    }

    /**
     * Sets the input of the submission
     *
     * @param input Input to be set
     */
    public void setInput(String input) {
        jEditorPane2.setText(input);
    }

    /**
     * Sets the Stderr of the submission
     *
     * @param stderr Stderr to be set
     */
    public void setStderr(String stderr) {
        jEditorPane4.setText(stderr);
    }

    /**
     * Sets the language of the submission
     *
     * @param lang Language to be set
     */
    public void setLanguage(String lang) {
        jLabel24.setText(lang);
    }

    /**
     * Show/Hides the Compilation Info section
     *
     * @param val Set to false if CmpInfo should be hidden
     */
    public void showCmpInfo(boolean val) {
        jLabel25.setVisible(val);
        jLabel26.setVisible(val);
        jLabel27.setVisible(val);
        jLabel28.setVisible(val);
        jLabel29.setVisible(val);
        jScrollPane3.setVisible(val);
        jEditorPane3.setVisible(val);
    }

    /**
     * Show/Hides the StdErr section
     *
     * @param val Set to false if StdErr should be hidden
     */
    public void showStdErr(boolean val) {
        jLabel9.setVisible(val);
        jLabel17.setVisible(val);
        jLabel18.setVisible(val);
        jScrollPane4.setVisible(val);
        jEditorPane4.setVisible(val);
    }

    /**
     * Show/Hides the Output section
     *
     * @param val Set to false if Output should be hidden
     */
    public void showOutput(boolean val) {
        jLabel8.setVisible(val);
        jLabel19.setVisible(val);
        jLabel20.setVisible(val);
        jLabel21.setVisible(val);
        jLabel22.setVisible(val);
        jLabel15.setVisible(val);
        jLabel16.setVisible(val);
        jScrollPane5.setVisible(val);
        jEditorPane5.setVisible(val);
    }

    /**
     * Show/Hides the Source Code section
     *
     * @param val Set to false if Source Code should be hidden
     */
    public void showSrcCode(boolean val) {
        jLabel3.setVisible(val);
        jLabel4.setVisible(val);
        jLabel5.setVisible(val);
        jLabel6.setVisible(val);
        jLabel11.setVisible(val);
        jScrollPane1.setVisible(val);
        jEditorPane1.setVisible(val);
    }

    /**
     * Show/Hides the Input section
     *
     * @param val Set to false if input should be hidden
     */
    public void showInput(boolean val) {
        jLabel7.setVisible(val);
        jLabel12.setVisible(val);
        jLabel13.setVisible(val);
        jLabel14.setVisible(val);
        jScrollPane2.setVisible(val);
        jEditorPane2.setVisible(val);
    }

    /**
     * Only show the Output Section
     */
    public void hideAllExceptInput() {
        showCmpInfo(false);
        showStdErr(false);
        showOutput(false);
        showSrcCode(false);
    }
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton jButton1;
    private javax.swing.JButton jButton2;
    private javax.swing.JEditorPane jEditorPane1;
    private javax.swing.JEditorPane jEditorPane2;
    private javax.swing.JEditorPane jEditorPane3;
    private javax.swing.JEditorPane jEditorPane4;
    private javax.swing.JEditorPane jEditorPane5;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel10;
    private javax.swing.JLabel jLabel11;
    private javax.swing.JLabel jLabel12;
    private javax.swing.JLabel jLabel13;
    private javax.swing.JLabel jLabel14;
    private javax.swing.JLabel jLabel15;
    private javax.swing.JLabel jLabel16;
    private javax.swing.JLabel jLabel17;
    private javax.swing.JLabel jLabel18;
    private javax.swing.JLabel jLabel19;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel20;
    private javax.swing.JLabel jLabel21;
    private javax.swing.JLabel jLabel22;
    private javax.swing.JLabel jLabel23;
    private javax.swing.JLabel jLabel24;
    private javax.swing.JLabel jLabel25;
    private javax.swing.JLabel jLabel26;
    private javax.swing.JLabel jLabel27;
    private javax.swing.JLabel jLabel28;
    private javax.swing.JLabel jLabel29;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel30;
    private javax.swing.JLabel jLabel31;
    private javax.swing.JLabel jLabel4;
    private javax.swing.JLabel jLabel5;
    private javax.swing.JLabel jLabel6;
    private javax.swing.JLabel jLabel7;
    private javax.swing.JLabel jLabel8;
    private javax.swing.JLabel jLabel9;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JProgressBar jProgressBar1;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JScrollPane jScrollPane3;
    private javax.swing.JScrollPane jScrollPane4;
    private javax.swing.JScrollPane jScrollPane5;
    private javax.swing.JTextField jTextField1;
    // End of variables declaration//GEN-END:variables
}
